/*
 * Atualizado por Davi Uezono em 12.10.2011 às 02h02min.
 */
package Objects;

public class Serpent implements CRUDClass {
  private String specie;
  private int serpentID, regionID, memberID;

  public Serpent(String specie, int serpentID, int regionID, int memberID) {
    this.specie = specie;
    this.serpentID = serpentID;
    this.regionID = regionID;
    this.memberID = memberID;
  }

    public String getSpecie() {
        return specie;
    }

    public void setSpecie(String specie) {
        this.specie = specie;
    }

    public int getSerpentID() {
        return serpentID;
    }

    public void setSerpentID(int serpentID) {
        this.serpentID = serpentID;
    }

    public int getRegionID() {
        return regionID;
    }

    public void setRegionID(int regionID) {
        this.regionID = regionID;
    }

    public int getMemberID() {
        return memberID;
    }

    public void setMemberID(int memberID) {
        this.memberID = memberID;
    }

// public Serpent(String specie, int serpentID, int regionID, int memberID)

  @Override
  public String toInsert() {
    return "INSERT INTO Serpent VALUES ('" + this.specie + "', " + this.serpentID + ", " + this.regionID + ", " + this.memberID + ");";
  }

  @Override
  public String toUpdate() {
    return "UPDATE Serpent SET SerpentID = '" + this.serpentID + ", Specie = '"
            + this.specie + "', RegionID = " + this.regionID + ", MemberID = " + this.memberID
            + " WHERE SerpentID = " + this.serpentID;
  }

  @Override
  public String toDelete() {
    return "DELETE FROM Feature WHERE Serpent = " + this.serpentID;
  }
}
